#include "common.h"
#include "log.h"
#define TAG "log_port"


static elab_device_t* console;
void LogWrite(char* buffer, short len)
{
  elab_device_write(console, buffer, len);
}
Log systemLog = {LogWrite, true, LOG_ALL };
void log_init(void)
{
    console = device_find("console");
    elab_assert(console != NULL);
    logRegister(&systemLog);
}

INIT_EXPORT(log_init, EXPORT_MIDWARE);
